<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="jump" uri="/jump/taglib"%>
<%String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<base href="<%=basePath%>admin/pack/greenteaPacking/guanyinwang/">
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
	<link rel="stylesheet" type="text/css" href="<%=basePath%>admin/pack/css/bagPack.css" />
	<script type="text/javascript" src="<%=basePath%>admin/pack/js/jquery-1.4.2.min.js"></script>
	<script language="JavaScript">
		selectId = ${selected}
		//alert(selectId);
	</script>
	<script type="text/javascript" src="<%=basePath%>admin/pack/js/bagPack.js"></script>
	<title>无标题文档</title>
<style type="text/css">
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
.STYLE1 {font-size: 12px}
.STYLE4 {
	font-size: 12px;
	color: #1F4A65;
	font-weight: bold;
}

a:link {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;

}
a:visited {
	font-size: 12px;
	color: #06482a;
	text-decoration: none;
}
a:hover {
	font-size: 12px;
	color: #FF0000;
	text-decoration: underline;
}
a:active {
	font-size: 12px;
	color: #FF0000;
	text-decoration: none;
}
.STYLE7 {font-size: 12}
</style>

<script>
var  highlightcolor='#eafcd5';
//此处clickcolor只能用win系统颜色代码才能成功,如果用#xxxxxx的代码就不行,还没搞清楚为什么:(
var  clickcolor='#51b2f6';
function  changeto(){
source=event.srcElement;
if  (source.tagName=="TR"||source.tagName=="TABLE")
return;
while(source.tagName!="TD")
source=source.parentElement;
source=source.parentElement;
cs  =  source.children;
//alert(cs.length);
if  (cs[1].style.backgroundColor!=highlightcolor&&source.id!="nc"&&cs[1].style.backgroundColor!=clickcolor)
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor=highlightcolor;
}
}

function  changeback(){
if  (event.fromElement.contains(event.toElement)||source.contains(event.toElement)||source.id=="nc")
return
if  (event.toElement!=source&&cs[1].style.backgroundColor!=clickcolor)
//source.style.backgroundColor=originalcolor
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor="";
}
}

function  clickto(){
source=event.srcElement;
if  (source.tagName=="TR"||source.tagName=="TABLE")
return;
while(source.tagName!="TD")
source=source.parentElement;
source=source.parentElement;
cs  =  source.children;
//alert(cs.length);
if  (cs[1].style.backgroundColor!=clickcolor&&source.id!="nc")
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor=clickcolor;
}
else
for(i=0;i<cs.length;i++){
	cs[i].style.backgroundColor="";
}
}
function jump(){
  var text = $('.checkTabIn a').text();
  //if(text=='半成品') {
    // window.location.href='ParticalPacking.jsp';
     //}
  //else
  if(text=="${descList[1]}") {
  	  //window.location.href='BoxPacking.jsp';
	  document.getElementById("selectFormId").submit();
  } 
}

/**
 * 包装时用到的全选……
 */
 function selectAll(){
	var text = $('.checkTabIn a').text();
	var val = $('#all').attr('checked');
	if(text=="${descList[1]}") {
		$('.contextIn input.STYLE2').attr({checked:val});
	 }
}
</script>
</head>
<body>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="30"><table width="100%" border="0px" cellspacing="0" cellpadding="0">
      <tr>
        <td width="15" height="30"><img src="<%=basePath%>admin/tab/images/tab_03.gif" width="15" height="30" /></td>
        <td width="1101" background="<%=basePath%>admin/tab/images/tab_05.gif"><img src="<%=basePath%>admin/tab/images/311.gif" width="16" height="16" /> <span class="STYLE4">袋包装处理管理</span></td>
        <td width="281" background="<%=basePath%>admin/tab/images/tab_05.gif"><table border="0" align="right" cellpadding="0" cellspacing="0">
            <tr>
              <td width="60"><table width="87%" border="0" cellpadding="0" cellspacing="0">
                  <tr align="center">
                    <td class="STYLE1">
                        <input id="all" onclick="selectAll()" type="checkbox" name="checkbox62"/>
                    </td>
                    <td class="STYLE1">全选</td>
                  </tr>
              </table></td>
              <td width="60"><table width="90%" border="0" cellpadding="0" cellspacing="0">
                  <tr align="center">
                    <td class="STYLE1"><img src="<%=basePath%>admin/tab/images/001.gif" width="14" height="14" /></td>
                    <td class="STYLE1"><a onclick="jump();" style="cursor: pointer">包装</a></td>
                  </tr>
              </table></td>
              <td width="60"><table width="90%" border="0" cellpadding="0" cellspacing="0">
                  <tr  align="center">
                    <td class="STYLE1"><img src="<%=basePath%>admin/tab/images/114.gif" width="14" height="14" /></td>
                    <td class="STYLE1">修改</td>
                  </tr>
              </table></td>
              <td width="52"><table width="88%" border="0" cellpadding="0" cellspacing="0">
                  <tr align="center">
                    <td class="STYLE1"><img src="<%=basePath%>admin/tab/images/083.gif" width="14" height="14" /></td>
                    <td class="STYLE1">删除</td>
                  </tr>
              </table></td>
            </tr>
        </table></td>
        <td width="14"><img src="<%=basePath%>admin/tab/images/tab_07.gif" width="14" height="30" /></td>
      </tr>
    </table></td>
  </tr>
  <!-- 选项卡的内容  -->
  <tr>
  	<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="9" background="<%=basePath%>admin/tab/images/tab_12.gif">&nbsp;</td>
        <td bgcolor="#f3ffe3"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98" onmouseover="changeto()"  onmouseout="changeback()">
        	<ul >
        	<c:forEach items="${descList}" var="desc">
        	<!--  class="checkTabIn"  -->
				<li style="font-size: 15px">
					<a href="#" onclick="return false;">${desc }</a>
				</li>
			</c:forEach>
			</ul>
        </table></td>
        <td width="9" background="<%=basePath%>admin/tab/images/tab_16.gif">&nbsp;</td>
      </tr>
    </table></td>
  </tr>
  <!-- 原料列表……进行第一道工序 -->
	<tr>
		<td class="check">  
			<div class="contextIn">
				<table width="100%" border="0" cellspacing="0" cellpadding="0">
			      <tr>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_12.gif">&nbsp;</td>
			        <td bgcolor="#f3ffe3"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98" onmouseover="changeto()"  onmouseout="changeback()">
			         <tr>
			            <td width="5%" height="26" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">选择</div></td>
			            <td width="10%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">半成品编号</div></td>
			            <td width="10%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">仓库来源</div></td>
			            <td width="10%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">重量</div></td>
			            <td width="10%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">质量</div></td>
			            <td  width="7%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">包装方式</div></td>
			            <td  width="7%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">生产时间</div></td>
			            <td width="10%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">描述</div></td>
			            <td width="7%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">粒子包装</div></td> 
			          </tr>
			     <c:forEach items="${listSemiFinishedProductPackage}" var="sfpp">
			         <tr>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE1">
			              <input name="checkboxSemi" type="checkbox" class="STYLE2"/>
			            </div></td>
			            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1">${sfpp.id } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${sfpp.storage.id } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${sfpp.weight } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${sfpp.quality } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${sfpp.wrapper } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${sfpp.time } </div></td>
						<td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /><span class="STYLE1"></span><a href="#" onclick="return false;"></a><span class="STYLE1">${sfpp.description }</span></div></td>
			            <td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center">
			            	<span class="STYLE2"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /> </span><span class="STYLE1"></span>
			            	<a href="ParticalPacking.jsp?semiFinishedProductPackageId=${sfpp.id }&packingFlowId=${packingFlowId}">粒子包装</a>
			            	<span class="STYLE1"></span></div></td>
			          </tr>
			      </c:forEach>
			        </table></td>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_16.gif">&nbsp;</td>
			      </tr>
			    </table>
			   <table width="100%" border="0" cellspacing="0" cellpadding="0">
				<tr>
				    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
				      <tr>
				        <td width="15" height="29"><img src="<%=basePath%>admin/tab/images/tab_20.gif" width="15" height="29" /></td>
				        <td background="<%=basePath%>admin/tab/images/tab_21.gif">&nbsp;
				        </td>
				      </tr>
				    </table></td>
				    <td width="14"><img src="<%=basePath%>admin/tab/images/tab_22.gif" width="14" height="29" /></td>
				 </tr>
			  </table>
			</div>
			<div>
			<form id="selectFormId" action="semiDataList" method="post">
				<table width="100%" border="0" cellspacing="0" cellpadding="0">
			      <tr>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_12.gif">&nbsp;</td>
			        <td bgcolor="#f3ffe3"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98" onmouseover="changeto()"  onmouseout="changeback()">
			         <tr>
			            <td width="3%" height="26" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">选择</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">商品编号</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">半成品编号</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装方式</div></td>
			            <td width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">重量</div></td>
			            <td width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">质量</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">生产日期</div></td>
					<!-- 人员、设备在详情那里显示，全部显示出来之后，就可以修改
			            <td width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装人员</div></td>
			            <td width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装设备</div></td>
			            <td  width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">修改</div></td>
					 -->			            
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">详情</div></td>
			            <td width="5%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">删除</div></td> 
			          </tr>
			     <c:forEach items="${listPar}" var="particle">
			         <tr>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE1">
			              <input name="checkboxPar" type="checkbox" class="STYLE2" value="${particle.particleProductId }"/>
			            </div></td>
			            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1">${particle.particleProductId }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${particle.semifinishedProductPackageId }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${particle.wrapper }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${particle.weight }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${particle.quality }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${particle.packTime }</div></td>
			            <!-- 人员、设备在详情那里显示，全部显示出来之后，就可以修改
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">包装人员</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">包装设备</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /><span class="STYLE1"></span><a href="#">修改</a><span class="STYLE1"></span></div></td>
			             -->
						<td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /><span class="STYLE1"></span><a href="#">详情</a><span class="STYLE1"></span></div></td>
			            <td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><span class="STYLE2"><img src="<%=basePath%>admin/tab/images/010.gif" width="9" height="9" /> </span><span class="STYLE1"></span><a href="delParticleProduct?particleProduct.particleProductId=${particle.particleProductId }">删除</a><span class="STYLE1"></span></div></td>
			          </tr>	
			     </c:forEach>		         		          
			        </table></td>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_16.gif">&nbsp;</td>
			      </tr>
			    </table>
			  </form>
			    <table width="100%" border="0" cellspacing="0" cellpadding="0">
				<tr>
				    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
				      <tr>
				        <td width="15" height="29"><img src="<%=basePath%>admin/tab/images/tab_20.gif" width="15" height="29" /></td>
				        <td background="<%=basePath%>admin/tab/images/tab_21.gif">&nbsp;
				        </td>
				      </tr>
				    </table></td>
				    <td width="14"><img src="<%=basePath%>admin/tab/images/tab_22.gif" width="14" height="29" /></td>
				 </tr>
			  </table>
			</div>
			<div>
				<table width="100%" border="0" cellspacing="0" cellpadding="0">
			      <tr>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_12.gif">&nbsp;</td>
			        <td bgcolor="#f3ffe3"><table width="99%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#c0de98" onmouseover="changeto()"  onmouseout="changeback()">
			         <tr>
			            <td width="4%" height="26" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">选择</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">商品编号</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">商品名称</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">重量</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">质量</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装方式</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">有效期</div></td>  
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">生产日期</div></td>
			            <!-- 
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包含粒茶</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装人员</div></td>
			            <td width="6%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">包装设备</div></td>
			            <td width="8%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">修改</div></td>
			             -->
			            <td width="8%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2 STYLE1">详情</div></td>
			            <td width="8%" height="18" background="<%=basePath%>admin/tab/images/tab_14.gif" class="STYLE1"><div align="center" class="STYLE2">删除</div></td> 
			          </tr>
			    <c:forEach items="${listBox}" var="box">
			         <tr>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE1">
			              <input name="checkboxBox" type="checkbox" class="STYLE2"/>
			            </div></td>
			            <td height="18" bgcolor="#FFFFFF" class="STYLE2"><div align="center" class="STYLE2 STYLE1">${box.boxProductId }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${godName } </div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${box.weight }</div></td>   
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${box.quality }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${box.wrapper }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${box.validity }</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">${box.packTime }</div></td>
			            <!-- 
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1"><a href="#" onclick="return false;">包含粒茶</a></div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">包装人员</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div align="center" class="STYLE2 STYLE1">包装设备</div></td>
			            <td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /><span class="STYLE1"> </span><a href="UpdateAirCheckInfo.jsp">修改</a><span class="STYLE1"></span></div></td>
			             -->
						<td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><img src="<%=basePath%>admin/tab/images//037.gif" width="9" height="9" /><span class="STYLE1"> </span><a href="#" onclick="return false;">详情</a><span class="STYLE1"></span></div></td>
			            <td height="18" bgcolor="#FFFFFF"><div class="STYLE1" align="center"><span class="STYLE2"><img src="<%=basePath%>admin/tab/images/010.gif" width="9" height="9" /> </span><span class="STYLE1"></span><a href="delBoxProduct?boxProduct.boxProductId=${box.boxProductId }">删除</a><span class="STYLE1"></span></div></td>
			          </tr>
			     </c:forEach>
			        </table></td>
			        <td width="9" background="<%=basePath%>admin/tab/images/tab_16.gif">&nbsp;</td>
			      </tr>
			    </table>
			    <table width="100%" border="0" cellspacing="0" cellpadding="0">
				<tr>
				    <td height="29"><table width="100%" border="0" cellspacing="0" cellpadding="0">
				      <tr>
				        <td width="15" height="29"><img src="<%=basePath%>admin/tab/images/tab_20.gif" width="15" height="29" /></td>
				        <td background="<%=basePath%>admin/tab/images/tab_21.gif">&nbsp;</td>
				      </tr>
				    </table></td>
				    <td width="14"><img src="<%=basePath%>admin/tab/images/tab_22.gif" width="14" height="29" /></td>
				 </tr>
			  </table>
			</div>
		</td>
	</tr>
</table>
</body>
</html>